home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The X-Philes (2nd Revision)
/
The X-Philes Number 1 (1995).iso
/
xphiles
/
hp48hor2
/
life.doc
< prev
next >
Wrap
Text File
|
1995-03-31
|
3KB
|
62 lines
Conway's "Game of Life", for the 48sx, parts written in ML.
LIFE is Freeware from Timm Ganske
Vordergasse 67
W-6054 Rodgau 1/Juegesheim
Germany
Date: 1 October 1991
[Note from Joe Horn: In case you've never heard of the classic "Game
of Life" invented by mathematician John Conway, you'll find Life
fascinating. It's a visual delight. Here's a thumbnail sketch of
what it's all about. When you're growing mold in a petri dish (or
when you see mushrooms growing in your lawn, or the macropopulation
density of inner cities, or mildew growing on your shower wall...),
you see definite patterns of growth (expansion and rearrangement) and
decay (death). If you divide up the growth space into a grid, each
cell has eight neighbors (one on each side and at each corner):
+--------+--------+--------+
| | | |
|neighbor|neighbor|neighbor|
| | | |
+--------+--------+--------+
| | | |
|neighbor| CELL |neighbor|
| | | |
+--------+--------+--------+
| | | |
|neighbor|neighbor|neighbor|
| | | |
+--------+--------+--------+
Conway proposed a simple model of growth & decay. If a living cell
has more than 3 living neighbors, it would die (overpopulation?
starvation? not enough privacy?), and if it has less than 2 living
neighbors, it also dies (loneliness? boredom?). Thus a living cell can
only survive with exactly two or three living neighbors. On the other
hand, a dead cell will come to life if it has exactly three living
neighbors. Each iteration therefore results in some cells coming to
life, some dying, and most staying the same. Although it is called the
"game" of Life, you don't "play" it, you just watch it. But I warn
you: it can be mesmerizing and highly addictive! -jkh-]
Usage:
LIFE expects a GROB from the stack and calculates Life until a key is
pressed; don't use ON.
LIFE1 calculates only one iteration of Life
Both return the actual graphic
BILD1
BILD2
Demo pictures, Bild 2 is the classical 'Gleiterkanone'
[Note: in English, it's commonly called a "walker gun". It's a
complex structure that creates "walkers", the tiny shapes that walk
across the screen. Other common shapes have names too, among Life
afficionados. -jkh-]